<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../js/vue.js"></script>
    <style>

    </style>
</head>
<body>
    <div id="root">
        <h2 >当前n的值是:{{n}}</h2>
        <button @click = "n++">点我n+1</button>
        <div v-if = "n === 1">我好帅</div>
        <div v-else-if = "n === 2">你好帅</div>
        <div v-else >我喜欢你</div>
        


    </div>

    <script>
        new Vue({
            el:'#root',
            data:{
                name:'我的秘密空间',
                n:'0'
            }

        })
    </script>
</body>
</html>